package com.kika.obwiki.resp;

import lombok.ToString;
//统一响应对象

@ToString
public class CommonResp<T> {
    //业务上的成功或失败
    private boolean success = true;
    //返回信息
    private String message;

    //返回泛型数据，自定义类型
    private T content;

    public CommonResp(boolean success, String message, T content) {
        this.success = success;
        this.message = message;
        this.content = content;
    }

    public CommonResp() {
    }

    public boolean isSuccess() {
        return success;
    }

    public void setSuccess(boolean success) {
        this.success = success;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public T getContent() {
        return content;
    }

    public void setContent(T content) {
        this.content = content;
    }
}
